package pojo;

import java.math.BigDecimal;
import java.util.Date;

// 费用记录类（ExpenseRecord）
public class ExpenseRecord {
    private int recordId;
    private String expenseType; // '收入' or '支出'
    private BigDecimal amount;
    private Date expenseDate;
    private String remarks;
    private String className;
    public ExpenseRecord() {
    }

    public ExpenseRecord(int recordId, String expenseType, BigDecimal amount, Date expenseDate, String remarks) {
        this.recordId = recordId;
        this.expenseType = expenseType;
        this.amount = amount;
        this.expenseDate = expenseDate;
        this.remarks = remarks;
    }

    // getters and setters

    public int getRecordId() {
        return recordId;
    }

    public void setRecordId(int recordId) {
        this.recordId = recordId;
    }

    public String getExpenseType() {
        return expenseType;
    }

    public void setExpenseType(String expenseType) {
        this.expenseType = expenseType;
    }

    public BigDecimal getAmount() {
        return amount;
    }

    public void setAmount(BigDecimal amount) {
        this.amount = amount;
    }

    public java.sql.Date getExpenseDate() {
        java.sql.Date date = new java.sql.Date(this.expenseDate.getTime());
        return  date;
    }

    public void setExpenseDate(Date expenseDate) {
        this.expenseDate = expenseDate;
    }

    public String getRemarks() {
        return remarks;
    }

    public void setRemarks(String remarks) {
        this.remarks = remarks;
    }

    public String getClassName() {
        return className;
    }

    public ExpenseRecord setClassName(String className) {
        this.className = className;
        return this;
    }
}
